<!DOCTYPE html>
<html>
<head>
<meta charset="UTF-8">

<title>module DEBUGGER__ - debug: Ruby Standard Library Documentation</title>


<script src="./js/navigation.js" defer></script>
<script src="./js/search.js" defer></script>
<script src="./js/search_index.js" defer></script>
<script src="./js/searcher.js" defer></script>
<script src="./js/darkfish.js" defer></script>

<script src="./js/jquery-3.2.0.min.js"></script>

<script src="./js/vue.min.js"></script>
<script src="./js/js.cookie.min.js"></script>

<link href="./css/fonts.css" rel="stylesheet">
<link id='rdoccss' href="./css/rdoc.css" rel="stylesheet">
<link href="./css/carbon17.css" rel="stylesheet">

<script type="text/javascript">
  var rdoc_rel_prefix = "./";
  var index_rel_prefix = "./";
  var darkModeCsseHref = "./css/rdoc-dm.css"
  var defaultModeCssHref = "./css/rdoc.css"
  // var cssDarkmode = Cookies.get('darkmode');
  
  if( Cookies.get("darkmode") == "true") {
	$('#rdoccss').attr("href", darkModeCsseHref);
}

//  https://cssdeck.com/blog/simple-jquery-stylesheet-switcher/

document.write('<style type="text/css">body{display:none}</style>');

</script>


</head>
<body id="top" role="document" class="module">
  <!-- this is class.html -->

  <div id='actionbar' >
    <div class='wrapper mdiv'>
      <ul class='grids g0'></ul>
    </div> 
    <!-- VERSION HEADER for 3.3.0.preview2 NOT FOUND -->
  </div> <!-- end action bar -->

  <div class='wrapper hdiv'>

    


    <nav id='vapp' role="navigation">
    <div id="project-navigation">
      <div id="home-section" role="region" title="Quick navigation" class="nav-section">
  <h2><a href="./index.html" rel="home">Home</a></h2>

  <div id="table-of-contents-navigation"  >
    <a href="./table_of_contents.html#pages">Pages</a>
    <a href="./table_of_contents.html#classes">Classes</a>
    <a href="./table_of_contents.html#methods">Methods</a>
  </div>
</div>

      <div id="search-section" role="search" class="project-section initially-hidden">
  <form action="#" method="get" accept-charset="utf-8">
    <div id="search-field-wrapper">
      <input id="search-field" role="combobox" aria-label="Search"
             aria-autocomplete="list" aria-controls="search-results"
             type="text" name="search" placeholder="Search" spellcheck="false"
             title="Type to search, Up and Down to navigate, Enter to load">
    </div>

    <ul id="search-results" aria-label="Search Results"
        aria-busy="false" aria-expanded="false"
        aria-atomic="false" class="initially-hidden"></ul>
  </form>
</div>

    </div>


    

    <button id='toggleThing' @click="toggleNav()" >Show/hide navigation</button>
    <div :class="isOpen ? 'block' : 'hidden' " id='toggleMe'>
      <div id="class-metadata">
        
        
        
        
        
<!-- Method Quickref -->
<div id="method-list-section" class="nav-section">
  <h3>Methods</h3>

  <ul class="link-list" role="directory">
    <li ><a href="#method-c-add_catch_breakpoint">::add_catch_breakpoint</a>
    <li ><a href="#method-c-add_line_breakpoint">::add_line_breakpoint</a>
    <li ><a href="#method-c-check_dir_authority">::check_dir_authority</a>
    <li ><a href="#method-c-check_loglevel">::check_loglevel</a>
    <li ><a href="#method-c-commands">::commands</a>
    <li ><a href="#method-c-compare_path">::compare_path</a>
    <li ><a href="#method-c-create_unix_domain_socket_name">::create_unix_domain_socket_name</a>
    <li ><a href="#method-c-create_unix_domain_socket_name_prefix">::create_unix_domain_socket_name_prefix</a>
    <li ><a href="#method-c-debug">::debug</a>
    <li ><a href="#method-c-help">::help</a>
    <li ><a href="#method-c-helps">::helps</a>
    <li ><a href="#method-c-info">::info</a>
    <li ><a href="#method-c-load_rc">::load_rc</a>
    <li ><a href="#method-c-log">::log</a>
    <li ><a href="#method-c-open">::open</a>
    <li ><a href="#method-c-open_tcp">::open_tcp</a>
    <li ><a href="#method-c-open_unix">::open_unix</a>
    <li ><a href="#method-c-parse_help">::parse_help</a>
    <li ><a href="#method-c-require_location">::require_location</a>
    <li ><a href="#method-c-safe_inspect">::safe_inspect</a>
    <li ><a href="#method-c-setup_initial_suspend">::setup_initial_suspend</a>
    <li ><a href="#method-c-skip-3F">::skip?</a>
    <li ><a href="#method-c-skip_all">::skip_all</a>
    <li ><a href="#method-c-start">::start</a>
    <li ><a href="#method-c-step_in">::step_in</a>
    <li ><a href="#method-c-unix_domain_socket_dir">::unix_domain_socket_dir</a>
    <li ><a href="#method-c-unix_domain_socket_homedir">::unix_domain_socket_homedir</a>
    <li ><a href="#method-c-unix_domain_socket_tmpdir">::unix_domain_socket_tmpdir</a>
    <li ><a href="#method-c-warn">::warn</a>
  </ul>
</div>

      </div>
     </div>
    </nav>


    <div id='extraz'><div class='adzbox-index'  >
      
     </div>         
    </div>

    <main role="main" aria-labelledby="module-DEBUGGER__">
    <h1 id="module-DEBUGGER__" class="module">
      module DEBUGGER__
    </h1>

    <section class="description">
    
<p>$VERBOSE = true</p>

    </section>

      <section id="5Buntitled-5D" class="documentation-section">


      <section class="constants-list">
      <header>
      <h3>Constants</h3>
      </header>
      <dl>
          <dt id="CONFIG">CONFIG
          <dd>
          <dt id="CONFIG_MAP">CONFIG_MAP
          <dd>
          <dt id="CONFIG_SET">CONFIG_SET
          <dd>
          <dt id="FrameInfo">FrameInfo
          <dd>
          <dt id="LOG_LEVELS">LOG_LEVELS
          <dd>
          <dt id="M_CLASS">M_CLASS
          <dd>
          <dt id="M_INSTANCE_VARIABLES">M_INSTANCE_VARIABLES
          <dd>
          <dt id="M_INSTANCE_VARIABLE_GET">M_INSTANCE_VARIABLE_GET
          <dd>
          <dt id="M_KIND_OF_P">M_KIND_OF_P
          <dd>
          <dt id="M_METHOD">M_METHOD
          <dd>
          <dt id="M_NAME">M_NAME
          <dd>
          <dt id="M_OBJECT_ID">M_OBJECT_ID
          <dd>
          <dt id="M_RESPOND_TO_P">M_RESPOND_TO_P
          <dd>
          <dt id="M_SINGLETON_CLASS">M_SINGLETON_CLASS
          <dd>
          <dt id="PresetCommands">PresetCommands
          <dd>
          <dt id="SHORT_INSPECT_LENGTH">SHORT_INSPECT_LENGTH
          <dd><p>Inspector</p>
          <dt id="SessionCommand">SessionCommand
          <dd>
          <dt id="VERSION">VERSION
          <dd>
        </dl>
        </section>



                <section id="public-class-5Buntitled-5D-method-details" class="method-section">
                <header>
                <h3>Public Class Methods</h3>
                </header>

                  <div id="method-c-add_catch_breakpoint" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">add_catch_breakpoint</span><span
                                class="method-args">(pat)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="add_catch_breakpoint-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2163</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">add_catch_breakpoint</span> <span class="ruby-identifier">pat</span>
  <span class="ruby-operator">::</span><span class="ruby-constant">DEBUGGER__</span><span class="ruby-operator">::</span><span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">add_catch_breakpoint</span> <span class="ruby-identifier">pat</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-add_line_breakpoint" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">add_line_breakpoint</span><span
                                class="method-args">(file, line, **kw)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>manual configuration methods</p>

                              <div class="method-source-code" id="add_line_breakpoint-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2159</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">add_line_breakpoint</span> <span class="ruby-identifier">file</span>, <span class="ruby-identifier">line</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
  <span class="ruby-operator">::</span><span class="ruby-constant">DEBUGGER__</span><span class="ruby-operator">::</span><span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">add_line_breakpoint</span> <span class="ruby-identifier">file</span>, <span class="ruby-identifier">line</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-check_dir_authority" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">check_dir_authority</span><span
                                class="method-args">(path)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>Unix domain socket configuration</p>

                              <div class="method-source-code" id="check_dir_authority-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 443</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">check_dir_authority</span> <span class="ruby-identifier">path</span>
  <span class="ruby-identifier">fs</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">stat</span>(<span class="ruby-identifier">path</span>)

  <span class="ruby-keyword">unless</span> (<span class="ruby-identifier">dir_uid</span> = <span class="ruby-identifier">fs</span>.<span class="ruby-identifier">uid</span>) <span class="ruby-operator">==</span> (<span class="ruby-identifier">uid</span> = <span class="ruby-constant">Process</span>.<span class="ruby-identifier">uid</span>)
    <span class="ruby-identifier">raise</span> <span class="ruby-node">&quot;#{path} uid is #{dir_uid}, but Process.uid is #{uid}&quot;</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">fs</span>.<span class="ruby-identifier">world_writable?</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-operator">!</span><span class="ruby-identifier">fs</span>.<span class="ruby-identifier">sticky?</span>
    <span class="ruby-identifier">raise</span> <span class="ruby-node">&quot;#{path} is world writable but not sticky&quot;</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">path</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-check_loglevel" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">check_loglevel</span><span
                                class="method-args">(level)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="check_loglevel-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2362</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">check_loglevel</span> <span class="ruby-identifier">level</span>
  <span class="ruby-identifier">lv</span> = <span class="ruby-constant">LOG_LEVELS</span>[<span class="ruby-identifier">level</span>]
  <span class="ruby-identifier">config_lv</span> = <span class="ruby-constant">LOG_LEVELS</span>[<span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:log_level</span>]]
  <span class="ruby-identifier">lv</span> <span class="ruby-operator">&lt;=</span> <span class="ruby-identifier">config_lv</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-commands" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">commands</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="commands-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 548</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">commands</span>
  (<span class="ruby-keyword">defined?</span>(<span class="ruby-ivar">@commands</span>) <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-ivar">@commands</span>) <span class="ruby-operator">||</span> (<span class="ruby-identifier">parse_help</span>; <span class="ruby-ivar">@commands</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-compare_path" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">compare_path</span><span
                                class="method-args">(a, b)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>For case insensitive file system (like Windows) Note that this check is not enough because case sensitive/insensitive is depend on the file system. So this check is only roughly estimation.</p>

                              <div class="method-source-code" id="compare_path-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2408</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">compare_path</span>(<span class="ruby-identifier">a</span>, <span class="ruby-identifier">b</span>)
  <span class="ruby-identifier">a</span>&amp;.<span class="ruby-identifier">downcase</span> <span class="ruby-operator">==</span> <span class="ruby-identifier">b</span>&amp;.<span class="ruby-identifier">downcase</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-create_unix_domain_socket_name" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">create_unix_domain_socket_name</span><span
                                class="method-args">(base_dir = unix_domain_socket_dir)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="create_unix_domain_socket_name-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 502</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">create_unix_domain_socket_name</span>(<span class="ruby-identifier">base_dir</span> = <span class="ruby-identifier">unix_domain_socket_dir</span>)
  <span class="ruby-identifier">create_unix_domain_socket_name_prefix</span>(<span class="ruby-identifier">base_dir</span>) <span class="ruby-operator">+</span> <span class="ruby-node">&quot;-#{Process.pid}&quot;</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-create_unix_domain_socket_name_prefix" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">create_unix_domain_socket_name_prefix</span><span
                                class="method-args">(base_dir = unix_domain_socket_dir)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="create_unix_domain_socket_name_prefix-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 497</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">create_unix_domain_socket_name_prefix</span>(<span class="ruby-identifier">base_dir</span> = <span class="ruby-identifier">unix_domain_socket_dir</span>)
  <span class="ruby-identifier">user</span> = <span class="ruby-constant">ENV</span>[<span class="ruby-string">&#39;USER&#39;</span>] <span class="ruby-operator">||</span> <span class="ruby-string">&#39;UnknownUser&#39;</span>
  <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">base_dir</span>, <span class="ruby-node">&quot;ruby-debug-#{user}&quot;</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-debug" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">debug</span><span
                                class="method-args">(&amp;b)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="debug-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2368</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">debug</span>(<span class="ruby-operator">&amp;</span><span class="ruby-identifier">b</span>)
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">check_loglevel</span> <span class="ruby-value">:DEBUG</span>
    <span class="ruby-identifier">log</span> <span class="ruby-value">:DEBUG</span>, <span class="ruby-identifier">b</span>.<span class="ruby-identifier">call</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-help" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">help</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="help-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 552</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">help</span>
  <span class="ruby-identifier">r</span> = []
  <span class="ruby-keyword">self</span>.<span class="ruby-identifier">helps</span>.<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">cat</span>, <span class="ruby-identifier">cmds</span><span class="ruby-operator">|</span>
    <span class="ruby-identifier">r</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-node">&quot;### #{cat}&quot;</span>
    <span class="ruby-identifier">r</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-string">&#39;&#39;</span>
    <span class="ruby-identifier">cmds</span>.<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">_</span>, <span class="ruby-identifier">desc</span><span class="ruby-operator">|</span>
      <span class="ruby-identifier">r</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-identifier">desc</span>
    }
    <span class="ruby-identifier">r</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-string">&#39;&#39;</span>
  }
  <span class="ruby-identifier">r</span>.<span class="ruby-identifier">join</span>(<span class="ruby-string">&quot;\n&quot;</span>)
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-helps" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">helps</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="helps-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 544</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">helps</span>
  (<span class="ruby-keyword">defined?</span>(<span class="ruby-ivar">@helps</span>) <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-ivar">@helps</span>) <span class="ruby-operator">||</span> <span class="ruby-identifier">parse_help</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-info" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">info</span><span
                                class="method-args">(msg)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="info-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2358</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">info</span> <span class="ruby-identifier">msg</span>
  <span class="ruby-identifier">log</span> <span class="ruby-value">:INFO</span>, <span class="ruby-identifier">msg</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-load_rc" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">load_rc</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="load_rc-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2278</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">load_rc</span>
  [[<span class="ruby-constant">File</span>.<span class="ruby-identifier">expand_path</span>(<span class="ruby-string">&#39;~/.rdbgrc&#39;</span>), <span class="ruby-keyword">true</span>],
   [<span class="ruby-constant">File</span>.<span class="ruby-identifier">expand_path</span>(<span class="ruby-string">&#39;~/.rdbgrc.rb&#39;</span>), <span class="ruby-keyword">true</span>],
   <span class="ruby-comment"># [&#39;./.rdbgrc&#39;, true], # disable because of security concern</span>
   [<span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:init_script</span>], <span class="ruby-keyword">false</span>],
   ].<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span>(<span class="ruby-identifier">path</span>, <span class="ruby-identifier">rc</span>)<span class="ruby-operator">|</span>
    <span class="ruby-keyword">next</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">path</span>
    <span class="ruby-keyword">next</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">rc</span> <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:no_rc</span>] <span class="ruby-comment"># ignore rc</span>

    <span class="ruby-keyword">if</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">file?</span> <span class="ruby-identifier">path</span>
      <span class="ruby-keyword">if</span> <span class="ruby-identifier">path</span>.<span class="ruby-identifier">end_with?</span>(<span class="ruby-string">&#39;.rb&#39;</span>)
        <span class="ruby-identifier">load</span> <span class="ruby-identifier">path</span>
      <span class="ruby-keyword">else</span>
        <span class="ruby-operator">::</span><span class="ruby-constant">DEBUGGER__</span><span class="ruby-operator">::</span><span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">add_preset_commands</span> <span class="ruby-identifier">path</span>, <span class="ruby-constant">File</span>.<span class="ruby-identifier">readlines</span>(<span class="ruby-identifier">path</span>)
      <span class="ruby-keyword">end</span>
    <span class="ruby-keyword">elsif</span> <span class="ruby-operator">!</span><span class="ruby-identifier">rc</span>
      <span class="ruby-identifier">warn</span> <span class="ruby-node">&quot;Not found: #{path}&quot;</span>
    <span class="ruby-keyword">end</span>
  }

  <span class="ruby-comment"># given debug commands</span>
  <span class="ruby-keyword">if</span> <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:commands</span>]
    <span class="ruby-identifier">cmds</span> = <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:commands</span>].<span class="ruby-identifier">split</span>(<span class="ruby-string">&#39;;;&#39;</span>)
    <span class="ruby-operator">::</span><span class="ruby-constant">DEBUGGER__</span><span class="ruby-operator">::</span><span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">add_preset_commands</span> <span class="ruby-string">&quot;commands&quot;</span>, <span class="ruby-identifier">cmds</span>, <span class="ruby-value">kick:</span> <span class="ruby-keyword">false</span>, <span class="ruby-value">continue:</span> <span class="ruby-keyword">false</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-log" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">log</span><span
                                class="method-args">(level, msg)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="log-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2374</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">log</span> <span class="ruby-identifier">level</span>, <span class="ruby-identifier">msg</span>
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">check_loglevel</span> <span class="ruby-identifier">level</span>
    <span class="ruby-ivar">@logfile</span> = <span class="ruby-constant">STDERR</span> <span class="ruby-keyword">unless</span> <span class="ruby-keyword">defined?</span> <span class="ruby-ivar">@logfile</span>
    <span class="ruby-keyword">return</span> <span class="ruby-keyword">if</span> <span class="ruby-ivar">@logfile</span>.<span class="ruby-identifier">closed?</span>

    <span class="ruby-keyword">if</span> <span class="ruby-keyword">defined?</span> <span class="ruby-constant">SESSION</span>
      <span class="ruby-identifier">pi</span> = <span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">process_info</span>
      <span class="ruby-identifier">process_info</span> = <span class="ruby-identifier">pi</span> <span class="ruby-operator">?</span> <span class="ruby-node">&quot;[#{pi}]&quot;</span> <span class="ruby-operator">:</span> <span class="ruby-keyword">nil</span>
    <span class="ruby-keyword">end</span>

    <span class="ruby-keyword">if</span> <span class="ruby-identifier">level</span> <span class="ruby-operator">==</span> <span class="ruby-value">:WARN</span>
      <span class="ruby-comment"># :WARN on debugger is general information</span>
      <span class="ruby-ivar">@logfile</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;DEBUGGER#{process_info}: #{msg}&quot;</span>
      <span class="ruby-ivar">@logfile</span>.<span class="ruby-identifier">flush</span>
    <span class="ruby-keyword">else</span>
      <span class="ruby-ivar">@logfile</span>.<span class="ruby-identifier">puts</span> <span class="ruby-node">&quot;DEBUGGER#{process_info} (#{level}): #{msg}&quot;</span>
      <span class="ruby-ivar">@logfile</span>.<span class="ruby-identifier">flush</span>
    <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-open" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">open</span><span
                                class="method-args">(host: nil, port: CONFIG[:port], sock_path: nil, sock_dir: nil, nonstop: false, **kw)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="open-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2200</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">open</span> <span class="ruby-value">host:</span> <span class="ruby-keyword">nil</span>, <span class="ruby-value">port:</span> <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:port</span>], <span class="ruby-value">sock_path:</span> <span class="ruby-keyword">nil</span>, <span class="ruby-value">sock_dir:</span> <span class="ruby-keyword">nil</span>, <span class="ruby-value">nonstop:</span> <span class="ruby-keyword">false</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
  <span class="ruby-constant">CONFIG</span>.<span class="ruby-identifier">set_config</span>(<span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>)
  <span class="ruby-identifier">require_relative</span> <span class="ruby-string">&#39;server&#39;</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">port</span> <span class="ruby-operator">||</span> <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:open</span>] <span class="ruby-operator">==</span> <span class="ruby-string">&#39;chrome&#39;</span> <span class="ruby-operator">||</span> (<span class="ruby-operator">!</span><span class="ruby-operator">::</span><span class="ruby-constant">Addrinfo</span>.<span class="ruby-identifier">respond_to?</span>(<span class="ruby-value">:unix</span>))
    <span class="ruby-identifier">open_tcp</span> <span class="ruby-value">host:</span> <span class="ruby-identifier">host</span>, <span class="ruby-value">port:</span> (<span class="ruby-identifier">port</span> <span class="ruby-operator">||</span> <span class="ruby-value">0</span>), <span class="ruby-value">nonstop:</span> <span class="ruby-identifier">nonstop</span>
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">open_unix</span> <span class="ruby-value">sock_path:</span> <span class="ruby-identifier">sock_path</span>, <span class="ruby-value">sock_dir:</span> <span class="ruby-identifier">sock_dir</span>, <span class="ruby-value">nonstop:</span> <span class="ruby-identifier">nonstop</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-open_tcp" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">open_tcp</span><span
                                class="method-args">(host: nil, port:, nonstop: false, **kw)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="open_tcp-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2211</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">open_tcp</span> <span class="ruby-value">host:</span> <span class="ruby-keyword">nil</span>, <span class="ruby-value">port:</span>, <span class="ruby-value">nonstop:</span> <span class="ruby-keyword">false</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
  <span class="ruby-constant">CONFIG</span>.<span class="ruby-identifier">set_config</span>(<span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>)
  <span class="ruby-identifier">require_relative</span> <span class="ruby-string">&#39;server&#39;</span>

  <span class="ruby-keyword">if</span> <span class="ruby-keyword">defined?</span> <span class="ruby-constant">SESSION</span>
    <span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">reset_ui</span> <span class="ruby-constant">UI_TcpServer</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">host:</span> <span class="ruby-identifier">host</span>, <span class="ruby-value">port:</span> <span class="ruby-identifier">port</span>)
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">initialize_session</span>{ <span class="ruby-constant">UI_TcpServer</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">host:</span> <span class="ruby-identifier">host</span>, <span class="ruby-value">port:</span> <span class="ruby-identifier">port</span>) }
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">setup_initial_suspend</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">nonstop</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-open_unix" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">open_unix</span><span
                                class="method-args">(sock_path: nil, sock_dir: nil, nonstop: false, **kw)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="open_unix-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2224</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">open_unix</span> <span class="ruby-value">sock_path:</span> <span class="ruby-keyword">nil</span>, <span class="ruby-value">sock_dir:</span> <span class="ruby-keyword">nil</span>, <span class="ruby-value">nonstop:</span> <span class="ruby-keyword">false</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
  <span class="ruby-constant">CONFIG</span>.<span class="ruby-identifier">set_config</span>(<span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>)
  <span class="ruby-identifier">require_relative</span> <span class="ruby-string">&#39;server&#39;</span>

  <span class="ruby-keyword">if</span> <span class="ruby-keyword">defined?</span> <span class="ruby-constant">SESSION</span>
    <span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">reset_ui</span> <span class="ruby-constant">UI_UnixDomainServer</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">sock_dir:</span> <span class="ruby-identifier">sock_dir</span>, <span class="ruby-value">sock_path:</span> <span class="ruby-identifier">sock_path</span>)
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">initialize_session</span>{ <span class="ruby-constant">UI_UnixDomainServer</span>.<span class="ruby-identifier">new</span>(<span class="ruby-value">sock_dir:</span> <span class="ruby-identifier">sock_dir</span>, <span class="ruby-value">sock_path:</span> <span class="ruby-identifier">sock_path</span>) }
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">setup_initial_suspend</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">nonstop</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-parse_help" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">parse_help</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>Help</p>

                              <div class="method-source-code" id="parse_help-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 508</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">parse_help</span>
  <span class="ruby-identifier">helps</span> = <span class="ruby-constant">Hash</span>.<span class="ruby-identifier">new</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">h</span>, <span class="ruby-identifier">k</span><span class="ruby-operator">|</span> <span class="ruby-identifier">h</span>[<span class="ruby-identifier">k</span>] = []}
  <span class="ruby-identifier">desc</span> = <span class="ruby-identifier">cat</span> = <span class="ruby-keyword">nil</span>
  <span class="ruby-identifier">cmds</span> = <span class="ruby-constant">Hash</span>.<span class="ruby-identifier">new</span>

  <span class="ruby-constant">File</span>.<span class="ruby-identifier">read</span>(<span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">__dir__</span>, <span class="ruby-string">&#39;session.rb&#39;</span>), <span class="ruby-value">encoding:</span> <span class="ruby-constant">Encoding</span><span class="ruby-operator">::</span><span class="ruby-constant">UTF_8</span>).<span class="ruby-identifier">each_line</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">line</span><span class="ruby-operator">|</span>
    <span class="ruby-keyword">case</span> <span class="ruby-identifier">line</span>
    <span class="ruby-keyword">when</span> <span class="ruby-regexp">/\A\s*### (.+)/</span>
      <span class="ruby-identifier">cat</span> = <span class="ruby-node">$1</span>
      <span class="ruby-keyword">break</span> <span class="ruby-keyword">if</span> <span class="ruby-node">$1</span> <span class="ruby-operator">==</span> <span class="ruby-string">&#39;END&#39;</span>
    <span class="ruby-keyword">when</span> <span class="ruby-regexp">/\A      register_command (.+)/</span>
      <span class="ruby-keyword">next</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">cat</span>
      <span class="ruby-keyword">next</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">desc</span>

      <span class="ruby-identifier">ws</span> = []
      <span class="ruby-node">$1</span>.<span class="ruby-identifier">gsub</span>(<span class="ruby-regexp">/&#39;([a-z]+)&#39;/</span>){<span class="ruby-operator">|</span><span class="ruby-identifier">w</span><span class="ruby-operator">|</span>
        <span class="ruby-identifier">ws</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-node">$1</span>
      }
      <span class="ruby-identifier">helps</span>[<span class="ruby-identifier">cat</span>] <span class="ruby-operator">&lt;&lt;</span> [<span class="ruby-identifier">ws</span>, <span class="ruby-identifier">desc</span>]
      <span class="ruby-identifier">desc</span> = <span class="ruby-keyword">nil</span>
      <span class="ruby-identifier">max_w</span> = <span class="ruby-identifier">ws</span>.<span class="ruby-identifier">max_by</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">w</span><span class="ruby-operator">|</span> <span class="ruby-identifier">w</span>.<span class="ruby-identifier">length</span>}
      <span class="ruby-identifier">ws</span>.<span class="ruby-identifier">each</span>{<span class="ruby-operator">|</span><span class="ruby-identifier">w</span><span class="ruby-operator">|</span>
        <span class="ruby-identifier">cmds</span>[<span class="ruby-identifier">w</span>] = <span class="ruby-identifier">max_w</span>
      }
    <span class="ruby-keyword">when</span> <span class="ruby-regexp">/\A\s+# (\s*\*.+)/</span>
      <span class="ruby-keyword">if</span> <span class="ruby-identifier">desc</span>
        <span class="ruby-identifier">desc</span> <span class="ruby-operator">&lt;&lt;</span> <span class="ruby-string">&quot;\n&quot;</span> <span class="ruby-operator">+</span> <span class="ruby-node">$1</span>
      <span class="ruby-keyword">else</span>
        <span class="ruby-identifier">desc</span> = <span class="ruby-node">$1</span>
      <span class="ruby-keyword">end</span>
    <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">end</span>
  <span class="ruby-ivar">@commands</span> = <span class="ruby-identifier">cmds</span>
  <span class="ruby-ivar">@helps</span> = <span class="ruby-identifier">helps</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-require_location" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">require_location</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>String for requiring location nil for -r</p>

                              <div class="method-source-code" id="require_location-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2169</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">require_location</span>
  <span class="ruby-identifier">locs</span> = <span class="ruby-identifier">caller_locations</span>
  <span class="ruby-identifier">dir_prefix</span> = <span class="ruby-regexp">/#{Regexp.escape(__dir__)}/</span>

  <span class="ruby-identifier">locs</span>.<span class="ruby-identifier">each</span> <span class="ruby-keyword">do</span> <span class="ruby-operator">|</span><span class="ruby-identifier">loc</span><span class="ruby-operator">|</span>
    <span class="ruby-keyword">case</span> <span class="ruby-identifier">loc</span>.<span class="ruby-identifier">absolute_path</span>
    <span class="ruby-keyword">when</span> <span class="ruby-identifier">dir_prefix</span>
    <span class="ruby-keyword">when</span> <span class="ruby-regexp">%r{rubygems/core_ext/kernel_require\.rb}</span>
    <span class="ruby-keyword">else</span>
      <span class="ruby-keyword">return</span> <span class="ruby-identifier">loc</span> <span class="ruby-keyword">if</span> <span class="ruby-identifier">loc</span>.<span class="ruby-identifier">absolute_path</span>
    <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">nil</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-safe_inspect" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">safe_inspect</span><span
                                class="method-args">(obj, max_length: SHORT_INSPECT_LENGTH, short: false)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="safe_inspect-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2336</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">safe_inspect</span> <span class="ruby-identifier">obj</span>, <span class="ruby-value">max_length:</span> <span class="ruby-constant">SHORT_INSPECT_LENGTH</span>, <span class="ruby-value">short:</span> <span class="ruby-keyword">false</span>
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">short</span>
    <span class="ruby-constant">LimitedPP</span>.<span class="ruby-identifier">pp</span>(<span class="ruby-identifier">obj</span>, <span class="ruby-identifier">max_length</span>)
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">obj</span>.<span class="ruby-identifier">inspect</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">rescue</span> <span class="ruby-constant">NoMethodError</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-identifier">e</span>
  <span class="ruby-identifier">klass</span>, <span class="ruby-identifier">oid</span> = <span class="ruby-constant">M_CLASS</span>.<span class="ruby-identifier">bind_call</span>(<span class="ruby-identifier">obj</span>), <span class="ruby-constant">M_OBJECT_ID</span>.<span class="ruby-identifier">bind_call</span>(<span class="ruby-identifier">obj</span>)
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">obj</span> <span class="ruby-operator">==</span> (<span class="ruby-identifier">r</span> = <span class="ruby-identifier">e</span>.<span class="ruby-identifier">receiver</span>)
    <span class="ruby-node">&quot;&lt;\##{klass.name}#{oid} does not have \#inspect&gt;&quot;</span>
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">rklass</span>, <span class="ruby-identifier">roid</span> = <span class="ruby-constant">M_CLASS</span>.<span class="ruby-identifier">bind_call</span>(<span class="ruby-identifier">r</span>), <span class="ruby-constant">M_OBJECT_ID</span>.<span class="ruby-identifier">bind_call</span>(<span class="ruby-identifier">r</span>)
    <span class="ruby-node">&quot;&lt;\##{klass.name}:#{roid} contains &lt;\##{rklass}:#{roid} and it does not have #inspect&gt;&quot;</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">rescue</span> <span class="ruby-constant">Exception</span> <span class="ruby-operator">=&gt;</span> <span class="ruby-identifier">e</span>
  <span class="ruby-node">&quot;&lt;#inspect raises #{e.inspect}&gt;&quot;</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-setup_initial_suspend" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">setup_initial_suspend</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>boot utilities</p>

                              <div class="method-source-code" id="setup_initial_suspend-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2239</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">setup_initial_suspend</span>
  <span class="ruby-keyword">if</span> <span class="ruby-operator">!</span><span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:nonstop</span>]
    <span class="ruby-keyword">case</span>
    <span class="ruby-keyword">when</span> <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:stop_at_load</span>]
      <span class="ruby-identifier">add_line_breakpoint</span> <span class="ruby-keyword">__FILE__</span>, <span class="ruby-keyword">__LINE__</span> <span class="ruby-operator">+</span> <span class="ruby-value">1</span>, <span class="ruby-value">oneshot:</span> <span class="ruby-keyword">true</span>, <span class="ruby-value">hook_call:</span> <span class="ruby-keyword">false</span>
      <span class="ruby-keyword">nil</span> <span class="ruby-comment"># stop here</span>
    <span class="ruby-keyword">when</span> <span class="ruby-identifier">path</span> = <span class="ruby-constant">ENV</span>[<span class="ruby-string">&#39;RUBY_DEBUG_INITIAL_SUSPEND_PATH&#39;</span>]
      <span class="ruby-identifier">add_line_breakpoint</span> <span class="ruby-identifier">path</span>, <span class="ruby-value">0</span>, <span class="ruby-value">oneshot:</span> <span class="ruby-keyword">true</span>, <span class="ruby-value">hook_call:</span> <span class="ruby-keyword">false</span>
    <span class="ruby-keyword">when</span> <span class="ruby-identifier">loc</span> = <span class="ruby-operator">::</span><span class="ruby-constant">DEBUGGER__</span>.<span class="ruby-identifier">require_location</span>
      <span class="ruby-comment"># require &#39;debug/start&#39; or &#39;debug&#39;</span>
      <span class="ruby-identifier">add_line_breakpoint</span> <span class="ruby-identifier">loc</span>.<span class="ruby-identifier">absolute_path</span>, <span class="ruby-identifier">loc</span>.<span class="ruby-identifier">lineno</span> <span class="ruby-operator">+</span> <span class="ruby-value">1</span>, <span class="ruby-value">oneshot:</span> <span class="ruby-keyword">true</span>, <span class="ruby-value">hook_call:</span> <span class="ruby-keyword">false</span>
    <span class="ruby-keyword">else</span>
      <span class="ruby-comment"># -r</span>
      <span class="ruby-identifier">add_line_breakpoint</span> <span class="ruby-identifier">$0</span>, <span class="ruby-value">0</span>, <span class="ruby-value">oneshot:</span> <span class="ruby-keyword">true</span>, <span class="ruby-value">hook_call:</span> <span class="ruby-keyword">false</span>
    <span class="ruby-keyword">end</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-skip-3F" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">skip?</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="skip-3F-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2273</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">skip?</span>
  <span class="ruby-ivar">@skip_all</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-skip_all" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">skip_all</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="skip_all-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2269</span>
<span class="ruby-keyword">def</span> <span class="ruby-identifier ruby-title">skip_all</span>
  <span class="ruby-ivar">@skip_all</span> = <span class="ruby-keyword">true</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-start" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">start</span><span
                                class="method-args">(nonstop: false, **kw)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              <p>start methods</p>

                              <div class="method-source-code" id="start-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2186</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">start</span> <span class="ruby-value">nonstop:</span> <span class="ruby-keyword">false</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
  <span class="ruby-constant">CONFIG</span>.<span class="ruby-identifier">set_config</span>(<span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>)

  <span class="ruby-keyword">if</span> <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:open</span>]
    <span class="ruby-identifier">open</span> <span class="ruby-value">nonstop:</span> <span class="ruby-identifier">nonstop</span>, <span class="ruby-operator">**</span><span class="ruby-identifier">kw</span>
  <span class="ruby-keyword">else</span>
    <span class="ruby-keyword">unless</span> <span class="ruby-keyword">defined?</span> <span class="ruby-constant">SESSION</span>
      <span class="ruby-identifier">require_relative</span> <span class="ruby-string">&#39;local&#39;</span>
      <span class="ruby-identifier">initialize_session</span>{ <span class="ruby-constant">UI_LocalConsole</span>.<span class="ruby-identifier">new</span> }
    <span class="ruby-keyword">end</span>
    <span class="ruby-identifier">setup_initial_suspend</span> <span class="ruby-keyword">unless</span> <span class="ruby-identifier">nonstop</span>
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-step_in" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">step_in</span><span
                                class="method-args">() { || ... }</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="step_in-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2395</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">step_in</span> <span class="ruby-operator">&amp;</span><span class="ruby-identifier">b</span>
  <span class="ruby-keyword">if</span> <span class="ruby-keyword">defined?</span>(<span class="ruby-constant">SESSION</span>) <span class="ruby-operator">&amp;&amp;</span> <span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">active?</span>
    <span class="ruby-constant">SESSION</span>.<span class="ruby-identifier">add_iseq_breakpoint</span> <span class="ruby-constant">RubyVM</span><span class="ruby-operator">::</span><span class="ruby-constant">InstructionSequence</span>.<span class="ruby-identifier">of</span>(<span class="ruby-identifier">b</span>), <span class="ruby-value">oneshot:</span> <span class="ruby-keyword">true</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-keyword">yield</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-unix_domain_socket_dir" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">unix_domain_socket_dir</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="unix_domain_socket_dir-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 484</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">unix_domain_socket_dir</span>
  <span class="ruby-keyword">case</span>
  <span class="ruby-keyword">when</span> <span class="ruby-identifier">path</span> = <span class="ruby-constant">CONFIG</span>[<span class="ruby-value">:sock_dir</span>]
  <span class="ruby-keyword">when</span> <span class="ruby-identifier">path</span> = <span class="ruby-constant">ENV</span>[<span class="ruby-string">&#39;XDG_RUNTIME_DIR&#39;</span>]
  <span class="ruby-keyword">when</span> <span class="ruby-identifier">path</span> = <span class="ruby-identifier">unix_domain_socket_tmpdir</span>
  <span class="ruby-keyword">when</span> <span class="ruby-identifier">path</span> = <span class="ruby-identifier">unix_domain_socket_homedir</span>
  <span class="ruby-keyword">else</span>
    <span class="ruby-identifier">raise</span> <span class="ruby-string">&#39;specify RUBY_DEBUG_SOCK_DIR environment variable.&#39;</span>
  <span class="ruby-keyword">end</span>

  <span class="ruby-identifier">path</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-unix_domain_socket_homedir" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">unix_domain_socket_homedir</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="unix_domain_socket_homedir-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 472</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">unix_domain_socket_homedir</span>
  <span class="ruby-keyword">if</span> <span class="ruby-identifier">home</span> = <span class="ruby-constant">ENV</span>[<span class="ruby-string">&#39;HOME&#39;</span>]
    <span class="ruby-identifier">path</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">home</span>, <span class="ruby-string">&#39;.ruby-debug-sock&#39;</span>)

    <span class="ruby-keyword">unless</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-identifier">path</span>)
      <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">mkdir</span>(<span class="ruby-identifier">path</span>, <span class="ruby-value">0700</span>)
    <span class="ruby-keyword">end</span>

    <span class="ruby-identifier">check_dir_authority</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-unix_domain_socket_tmpdir" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">unix_domain_socket_tmpdir</span><span
                                class="method-args">()</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="unix_domain_socket_tmpdir-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/config.rb, line 457</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">unix_domain_socket_tmpdir</span>
  <span class="ruby-identifier">require</span> <span class="ruby-string">&#39;tmpdir&#39;</span>

  <span class="ruby-keyword">if</span> <span class="ruby-identifier">tmpdir</span> = <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">tmpdir</span>
    <span class="ruby-identifier">path</span> = <span class="ruby-constant">File</span>.<span class="ruby-identifier">join</span>(<span class="ruby-identifier">tmpdir</span>, <span class="ruby-node">&quot;ruby-debug-sock-#{Process.uid}&quot;</span>)

    <span class="ruby-keyword">unless</span> <span class="ruby-constant">File</span>.<span class="ruby-identifier">exist?</span>(<span class="ruby-identifier">path</span>)
      <span class="ruby-identifier">d</span> = <span class="ruby-constant">Dir</span>.<span class="ruby-identifier">mktmpdir</span>
      <span class="ruby-constant">File</span>.<span class="ruby-identifier">rename</span>(<span class="ruby-identifier">d</span>, <span class="ruby-identifier">path</span>)
    <span class="ruby-keyword">end</span>

    <span class="ruby-identifier">check_dir_authority</span>(<span class="ruby-identifier">path</span>)
  <span class="ruby-keyword">end</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                  <div id="method-c-warn" class="method-detail ">
                            <div class="method-heading">
                              <span class="method-name">warn</span><span
                                class="method-args">(msg)</span>
                              <span class="method-click-advice">click to toggle source</span>
                            </div>

                            <div class="method-description">
                              

                              <div class="method-source-code" id="warn-source">
            <pre><span class="ruby-comment"># File debug-1.8.0/lib/debug/session.rb, line 2354</span>
<span class="ruby-keyword">def</span> <span class="ruby-keyword">self</span>.<span class="ruby-identifier ruby-title">warn</span> <span class="ruby-identifier">msg</span>
  <span class="ruby-identifier">log</span> <span class="ruby-value">:WARN</span>, <span class="ruby-identifier">msg</span>
<span class="ruby-keyword">end</span></pre>
                              </div>
                            </div>


                          </div>

                          </section>

              </section>
              </main>



            </div>  <!--  class='wrapper hdiv' -->


<footer id="validator-badges" role="contentinfo">
<p><a href="https://validator.w3.org/check/referer">Validate</a></p>
<p>Generated by <a href="https://ruby.github.io/rdoc/">RDoc</a> 6.4.0.</p>
<p>Based on <a href="https://github.com/ged/darkfish/">Darkfish</a> by <a href="http://deveiate.org">Michael Granger</a>.</p>

  
    <p><p><a href="https://ruby-doc.org">Ruby-doc.org</a> is provided by <a href="https://jamesbritt.com">James Britt</a> and <a href="https://neurogami.com">Neurogami</a>. </p><p><a href="https://jamesbritt.bandcamp.com/">Hack your world.  Feed your head.  Live curious</a>.</p>
</p>
  
  </footer>

<script type="text/javascript">


  let ads  = $("#carbonads-container").children().detach();


  function swapMode() {
    var cookieName = 'darkmode';
    var cssDarkmode = Cookies.get(cookieName);
    console.log("***** swapMode! " + cssDarkmode + " *****");


    if (cssDarkmode == "true") {
      console.log("We have dark mode, set the css to light ...");
      $('#rdoccss').attr("href", defaultModeCssHref);
      $('#cssSelect').text("Dark mode");
      cssDarkmode = "false";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    } else {
      console.log("We not have dark mode, set the css to dark ...");
      $('#rdoccss').attr("href", darkModeCsseHref);
      $('#cssSelect').text("Light mode");
      cssDarkmode = "true";
      console.log("swapMode! Now set cookie to " + cssDarkmode);
      Cookies.set(cookieName, cssDarkmode);

    }

    console.log("  --------------- ");
  }


const vueCssApp = new Vue({
el: '#menubar',
data: {
isDark: false
},
methods: {
toggleClass: function(event){
this.isDark = !this.isDark;
}
}
})

const vueApp = new Vue({
el: '#vapp',
data: { 
isOpen: true
},

mounted() {
this.handleResize();
this.manage_mob_classes();
window.addEventListener('resize', this.handleResize)
//this.isOpen !=  (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},
destroyed() {
window.removeEventListener('resize', this.handleResize)
},
created() {
//manage_mob_classes();
},

methods : {
isMobile() {
  return (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent));
},

  handleResize() {
    if (!this.isMobile()) {
      this.isOpen = window.innerWidth > 800;
    }
  },

  manage_mob_classes() {
    if (/Android|webOS|iPhone|iPad|iPod|BlackBerry|IEMobile|Opera Mini/i.test(navigator.userAgent)) {
      $("nav").addClass("mob_nav");
      $("main").addClass("mob_main");
      $("#extraz").addClass("mob_extraz");
      $("#carbonads-container").addClass("mob_carbonads-container");
      this.isOpen  = false;
    } else {
      $("nav").removeClass("mob_nav") 
        $("main").removeClass("mob_main");
      $("#extraz").removeClass("mob_extraz");
      $("#carbonads-container").removeClass("mob_carbonads-container");
      this.isOpen  = true;
    }
  },

  toggleNav() {
    this.isOpen =! this.isOpen ;
    // alert("Toggle nav!");
    console.log("toggleNav() click: " + this.isOpen );
  }
}
})

$("#carbonads-container").append(ads);


$(function() {

    var darkmode = Cookies.get("darkmode");
    console.log("Document ready: " + darkmode);

    if ( darkmode  == "true" ) {
      $('#cssSelect').text("Light mode");
    } else {
      $('#cssSelect').text("Dark mode");
     }

    $('body').css('display','block');
    });

</script>

    
  </body> 
</html>

